<%@page import="org.apache.commons.lang.StringUtils"%>
<%@page import="com.test.google.app.common.SysSetting"%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>后台管理 - Xite</title>
    <link href="/css/bootstrap.xuper.css" rel="stylesheet" type="text/css"/>
    <link href="/css/default.css" rel="stylesheet" type="text/css"/>
    <script type="text/javascript" src="/js/jquery-1.8.2.min.js"></script>
    <!--[if IE 6]>
    <script language="javascript" type="text/javascript" src="/js/DD_belatedPNG_0.0.8a-min.js"></script>
    <script type="text/javascript">
        $(function(){
            DD_belatedPNG.fix('.png-fix');
        });
    </script>
    <![endif]-->
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
    <tr>
        <td height="100" valign="bottom">
            <table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
                <tr>
                    <td class="" width="1064" height="100" valign="bottom">
                        <!--<div class="png-fix"></div>-->
                    </td>
                </tr>
            </table>
        </td>
    </tr>
    <tr>
        <td height="117" valign="top">
            <table width="900" height="100%" border="0" align="center" cellpadding="0" cellspacing="0"
                   bgcolor="#FFFFFF">
                <tr>
                    <td width="8" height="8" align="left" valign="top" background="/img/left-middle.gif"><img
                            src="/img/left-top.gif" width="8" height="8"/></td>
                    <td width="984" height="8" valign="top"><img src="/img/top-middle.gif" width="984" height="8"/></td>
                    <td width="10" align="right" valign="top"><img src="/img/right-top.gif" width="8" height="8"/></td>
                </tr>
                <tr>
                    <td width="8" height="423" valign="top" background="/img/left-middle.gif"><img
                            src="/img/left-middle.gif" width="8" height="2"/></td>
                    <td valign="top">
                        <table id="main-container" width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
                            <tr>
                                <td width="195" height="389" valign="top">
									<jsp:include page="../sys/menu.jsp" />
                                </td>
                                <td width="19" valign="top" background="/img/splitmiddle.gif"><img
                                        src="/img/splitmiddle.gif" width="10" height="10"/></td>
                                <td width="770" valign="top">
                                    <div id="container">
<div id="datas">
	<%if (request.getAttribute("msg") != null) {%>
		${msg}
	<%} %>

    <form class="form-horizontal zhcn" action="../sys/updateAdminPwd.do" method="post">
        <h4 class="page-header zhcn">管理员密码
            <div style="float: right;" class="clearfix">
                <button id="btn_passwd_update" class="btn btn-primary"
                        data-loading-text="提交中..." data-editing-text="提交修改"
                        data-complete-text="更新成功!">修改密码</button>
            </div>
        </h4>
        <div class="control-group">
            <label class="control-label">新密码: </label>
            <div class="controls">
                <input class="input-large" type="password" name="pwd" value="" id="txt_passwd"/>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">重复新密码: </label>
            <div class="controls">
                <input class="input-large" type="password" name="pwd2" value="" id="txt_passwd2"/>
            </div>
        </div>
    </form>
    <br />

    <form class="form-horizontal zhcn" action="updateCCCgf.do" method="post">
        <h4 class="page-header zhcn">CC参数
            <div style="float: right;" class="clearfix">
                <button id="btn_cc_update" class="btn btn-primary"
                        data-loading-text="提交中..." data-editing-text="提交修改"
                        data-complete-text="更新成功!">提交修改</button>
            </div>
        </h4>
        <div class="control-group">
            <label class="control-label">CC开启模式: </label>
            <div class="controls">
                <select name="ccSwitch" type="text" id="txt_cc_switch" value="<%=SysSetting.getCcSwitch()%>">
                    <option value="">--请选择--</option>
                    <option value="auto" <%=SysSetting.getCcSwitch().equals("auto")?"selected":""%>>自动模式</option>
                    <option value="on" <%=SysSetting.getCcSwitch().equals("on")?"selected":""%>>强制开启</option>
                </select>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">触发请求数量<br />(仅自动模式有效): </label>
            <div class="controls">
                <input class="input-large" type="number" name="ccTrigger" value="<%=SysSetting.getCcTrigger() == null ? "" : SysSetting.getCcTrigger()%>" id="txt_cc_cc_trigger"//>
            </div>
        </div>
    </form>
    <br />
    
    <form class="form-horizontal zhcn" action="updateRedirectCfg.do" method="post">
        <h4 class="page-header zhcn">320重定向配置
            <div style="float: right;" class="clearfix">
                <button id="btn_cc_update" class="btn btn-primary"
                        data-loading-text="提交中..." data-editing-text="提交修改"
                        data-complete-text="更新成功!">提交修改</button>
            </div>
        </h4>
        <div class="control-group">
            <label class="control-label">空间: </label>
            <div class="controls">
                <input class="input-large" type="text" name="redirectFrom" value="<%=SysSetting.getRedirectFrom()%>"/>
                <span class="help-inline">如：/baidu</span>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">重定向页面：</label>
            <div class="controls">
                <input class="input-large" type="text" name="redirectTo" value="<%=SysSetting.getRedirectTo()%>"/>
            	<span class="help-inline">如: http://www.baidu.com</span>
            </div>
        </div>
    </form>
    <br />
    

<!--
    <form class="form-horizontal zhcn" action="/haoyangdettiis/hostname.do" method="post">
        <h4 class="page-header zhcn">管理员访问限制域名
            <div style="float: right;" class="clearfix">
                <button id="btn_hostname_update" class="btn btn-primary"
                        data-loading-text="提交中..." data-editing-text="提交修改"
                        data-complete-text="更新成功!">修改域名</button>
            </div>
        </h4>
        <div class="control-group">
            <label class="control-label">限制域名: </label>
            <div class="controls">
                <input class="input-large" name="hostname" type="text" value="*" id="txt_hostname"/>
                <span class="help-inline">如: * 或者 baidu.com, 不需要加http://</span>
            </div>
        </div>
    </form>
    <br />


    <form class="form-horizontal zhcn" action="/haoyangdettiis/update_range.do" method="post">
        <input type="hidden" value="add" name="action" />
        <h4 class="page-header zhcn">管理员访问限制ip段</h4>
        <div class="control-group">
            <table id="categories" width="100%" class="gridtable">
                <tr>
                    <th>#</th>
                    <th>起始</th>
                    <th>结束</th>
                    <th>操作</th>
                </tr>
                <tr class="cate1_temp" style="vertical-align: top;">
                    <td>1</td>
                    <td>0.0.0.0</td>
                    <td>255.255.255.255</td>
                    <td><a style="color: red;" href="update_range.do?action=del&range=0.0.0.0_255.255.255.255"
                                       onclick="return confirm('您确定要删除此ip段吗?')">[删除]</a></td>
                </tr>
                <tr>
                    <td style="color: red">[新增]</td>
                    <td><input type="text" name="ip_left" class="input-medium" style="text-align: center" placeholder="0.0.0.0" /></td>
                    <td><input type="text" name="ip_right" class="input-medium" style="text-align: center" placeholder="255.255.255.255"/></td>
                    <td><input type="submit" class="btn btn-primary" value="添加"></td>
                </tr>
            </table><br />
        </div>
    </form>
    <br />
    <div class="form-actions">
        <a class="btn btn-danger" href="/haoyangdettiis/finish_config.do"
           onclick="return confirm('您确定要完成安装吗? 此操作不可逆转!!')">完成安装</a>
    </div>
-->
</div>
<style type="text/css">
    #categories td{
        font-size: 14px;
    }
</style>
                                    </div>
                                </td>
                            </tr>
                        </table>
                    </td>
                    <td width="8" valign="top" background="/img/right-middle.gif"><img
                            src="/img/right-middle.gif"
                            width="8" height="2"/></td>
                </tr>
                <tr>
                    <td height="8" align="left" valign="top" background="/img/left-middle.gif"><img
                            src="/img/left-bottom.gif" width="8" height="8"/></td>
                    <td height="8" valign="top"><img src="/img/bottom-middle.gif" width="984" height="8"/></td>
                    <td width="10" height="8" align="right" valign="top" background="/img/right-middle.gif"><img
                            src="/img/right-bottom.gif" width="8" height="8"/></td>
                </tr>
            </table>
        </td>
    </tr>
</table>
<table width="100%" height="154" border="0" cellpadding="0" cellspacing="0">
    <tr>
        <td>
            <table width="800" height="154" border="0" align="center" cellpadding="0" cellspacing="0">
                <tr>
                    <td width="1000" valign="top">
                        <table width="800" border="0" cellspacing="0" cellpadding="0">
                            <tr>
                                <td width="14" background="/img/drop-middle.gif"><img src="/img/drop-left.gif"
                                                                                          width="6" height="73"/></td>
                                <td width="979" valign="bottom" background="/img/drop-middle.gif">
                                    <div align="center">
                                        <div align="center">
                                            <div align="center" style="color:#006699;">
                                                Copyright &copy; 2013 Xite
                                            </div>
                                        </div>
                                    </div>
                                </td>
                                <td width="10" valign="top" background="/img/drop-middle.gif">
                                    <div align="right"><img src="/img/drop-right.gif" width="6" height="73"/></div>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
        </td>
    </tr>
</table>
</body>
</html>
